<div id="content">
    <?php
    $IdReunion = $_GET['IdReunion'];
    $oPDO = new PdoReunion();

    $reunion = $oPDO->readOne($IdReunion);

    include("./PDO/PdoLieu.php"); //On inclut les fonctions PDO (create / update etc...)
    include("./class/Lieu.php"); //On inclut les fonctions PDO (create / update etc...)

    $lieu = new PdoLieu();
    $lieu = $lieu->readAll();
    
    echo "<form id='formulaire' action='index.php?route=reunion&action=traitement_modif' method='post'>";

    echo "<label>Nom</label>";
    echo "<input type='text' name='NOMREUNION' value='" . $reunion->getNomReunion() . "'/>";

    echo "<label>Date</label>";
    echo "<input type='text' name='DATEREUNION' value='". $reunion->getDateReunion() ."'/>";

    echo "<input type='hidden' name='IDREUNION' value='" . $reunion->getIdReunion() . "' />";
    echo "<label>Lieu</label>";
    echo '<select name="IDLIEU" size="1">';
    foreach ($lieu as $unlieu) {
        echo '<option value="' . $unlieu["IDLIEU"] . '">' . $unlieu["NOMLIEU"] . " " . $unlieu["CODEPOSTALLIEU"] . '</option>';
    }
    echo '</select>' . "<br/>";
    
    echo "<input type='submit'  value='Valider'>";

    echo "</form>";

    echo "<br /><br /><br /><br /><br />";
    ?></div>